{
char *cmd =
xmalloc (strlen (tagfile) + whatlen_max +
- sizeof "mv..OTAGS;fgrep -v '\t\t' OTAGS >;rm OTAGS");
+ sizeof "mv..OTAGS;grep -Fv '\t\t' OTAGS >;rm OTAGS");
for (i = 0; i < current_arg; ++i)
{
switch (argbuffer[i].arg_type)
}
char *z = stpcpy (cmd, "mv ");
z = stpcpy (z, tagfile);
- z = stpcpy (z, " OTAGS;fgrep -v '\t");
+ z = stpcpy (z, " OTAGS;grep -Fv '\t");
z = stpcpy (z, argbuffer[i].what);
z = stpcpy (z, "\t' OTAGS >");
z = stpcpy (z, tagfile);
Refers to `semantic-symref-tool', to determine the reference tool to use
for the current buffer.
Returns an object of class `semantic-symref-result'."
- (interactive "sEgrep style Regexp: ")
+ (interactive "sGrep -E style Regexp: ")
(let* ((inst (semantic-symref-instantiate
:searchfor text
:searchtype 'regexp
(cmd (progn
(set-text-properties 0 (length args)
'(invisible t) args)
- (format "%s -n %s" command args)))
+ (format "%s -n %s"
+ (pcase command
+ ("egrep" "grep -E")
+ ("fgrep" "grep -F")
+ (x x))
+ args)))
compilation-scroll-output)
(grep cmd)))))
(eshell-grep "grep" args t))
(defun eshell/egrep (&rest args)
- "Use Emacs grep facility instead of calling external egrep."
+ "Use Emacs grep facility instead of calling external grep -E."
(eshell-grep "egrep" args t))
(defun eshell/fgrep (&rest args)
- "Use Emacs grep facility instead of calling external fgrep."
+ "Use Emacs grep facility instead of calling external grep -F."
(eshell-grep "fgrep" args t))
(defun eshell/agrep (&rest args)
For example, to retrieve the second element of a user's record in
'/etc/passwd', the variable reference would look like:
- ${egrep johnw /etc/passwd}[: 2]"
+ ${grep johnw /etc/passwd}[: 2]"
(while indices
(let ((refs (car indices)))
(when (stringp value)
:type 'boolean :group 'ada)
(defcustom ada-xref-search-with-egrep t
- "If non-nil, use egrep to find the possible declarations for an entity.
+ "If non-nil, use grep -E to find the possible declarations for an entity.
This alternate method is used when the exact location was not found in the
information provided by GNAT. However, it might be expensive if you have a lot
of sources, since it will search in all the files in your project."
exist.
This function attempts to find the possible declarations for the identifier
anywhere in the object path.
-This command requires the external `egrep' program to be available.
+This command requires the external `grep' program to be available.
This works well when one is using an external library and wants to find
the declaration and documentation of the subprograms one is using."
(defcustom ispell-grep-command
- ;; MS-Windows/MS-DOS have `egrep' as a Unix shell script, so they
- ;; cannot invoke it. Use "grep -E" instead (see ispell-grep-options
- ;; below).
- (if (memq system-type '(windows-nt ms-dos)) "grep" "egrep")
+ "grep"
"Name of the grep command for search processes."
:type 'string
:group 'ispell)
(defcustom ispell-grep-options
- (if (memq system-type '(windows-nt ms-dos)) "-Ei" "-i")
+ "-Ei"
"String of options to use when running the program in `ispell-grep-command'.
-Should probably be \"-i\" or \"-e\".
-Some machines (like the NeXT) don't support \"-i\"."
+Should probably be \"-Ei\"."
:type 'string
:group 'ispell)
(defun ispell-lookup-words (word &optional lookup-dict)
"Look up WORD in optional word-list dictionary LOOKUP-DICT.
A `*' serves as a wild card. If no wild cards, `look' is used if it exists.
-Otherwise the variable `ispell-grep-command' contains the command used to
-search for the words (usually egrep).
+Otherwise the variable `ispell-grep-command' contains the command
+\(usually \"grep\") used to search for the words.
Optional second argument contains the dictionary to use; the default is
`ispell-alternate-dictionary', overridden by `ispell-complete-word-dict'